<!DOCTYPE html>
<html>
<head>
    <title></title>
		<#include "/header.html">
</head>
<body>
<div id="rrapp" v-cloak>
    <div v-show="showList">
        <div class="grid-btn">
            <div class="form-group col-sm-2">
                <select class="form-control" v-model="q.appID" @keyup.enter="query">
                    <option value="" selected disabled>请选择appid</option>
                    <option value="99a22c16-bd87-498e-a2a8-c55bf02b0b9d" selected>99a22c16-bd87-498e-a2a8-c55bf02b0b9d</option>
                    <option value="1">1</option>
                </select>
            </div>
            <div class="form-group col-sm-2">
                <input type="text" class="form-control" v-model="q.appname" @keyup.enter="query" placeholder="用户名">
            </div>
            <a class="btn btn-default" @click="query">查询</a>

            <#if shiro.hasPermission("appManagement:appupdate:save")>
            <a class="btn btn-primary" @click="add"><i class="fa fa-plus"></i>&nbsp;新增</a>
			</#if>
			<#if shiro.hasPermission("appManagement:appupdate:update")>
            <a class="btn btn-primary" @click="update"><i class="fa fa-pencil-square-o"></i>&nbsp;修改</a>
			</#if>
			<#if shiro.hasPermission("appManagement:appupdate:delete")>
            <a class="btn btn-primary" @click="del"><i class="fa fa-trash-o"></i>&nbsp;删除</a>
			</#if>
        </div>
        <table id="jqGrid"></table>
        <div id="jqGridPager"></div>
    </div>

    <div v-show="!showList" class="panel panel-default" align="center">
        <div class="panel-heading">{{title}}</div>
        <form class="form-horizontal" style="width:90%!important;">
            <div class="form-group">
                <div class="col-sm-2 control-label" style="width: 10%;">appID</div>
                <div class="col-sm-10" style="width: 40%;">
                    <!--<input type="text" class="form-control" width="80%" v-model="appUpdate.appid" placeholder=""/>-->
                    <select class="form-control" v-model="appUpdate.appid" @keyup.enter="query">
                        <option value="99a22c16-bd87-498e-a2a8-c55bf02b0b9d" selected>99a22c16-bd87-498e-a2a8-c55bf02b0b9d</option>
                        <option value="1" selected>1</option>
                    </select>
                </div>
                <div class="col-sm-2 control-label" style="width: 10%;">app名字</div>
                <div class="col-sm-10" style="width: 40%;">
                    <input type="text" class="form-control" width="80%" v-model="appUpdate.appname" placeholder="app名字"/>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label" style="width: 10%;">强制更新</div>
                <div class="col-sm-10" style="width: 40%;">
                    <!--<input type="text" class="form-control" width="80%" v-model="appUpdate.forcesign" placeholder=""/>-->
                    <select class="form-control" v-model="appUpdate.forcesign" @keyup.enter="query">
                        <option value="1">是</option>
                        <option value="0">否</option>
                    </select>
                </div>
                <div class="col-sm-2 control-label" style="width: 10%;">更新地址</div>
                <div class="col-sm-10" style="width: 40%;">
                    <input type="text" class="form-control" width="80%" v-model="appUpdate.updateurl" placeholder="更新地址"/>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label" style="width: 10%;">更新信息</div>
                <div class="col-sm-10" style="width: 90%;">
                    <input type="text" class="form-control" width="80%" v-model="appUpdate.updateinfo" placeholder="更新信息"/>
                </div>

            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label" style="width: 10%;">主版本号</div>
                <div class="col-sm-10" style="width: 90%;">
                    <input type="text" class="form-control" width="80%" v-model="appUpdate.mainno" placeholder="主版本号"/>
                    <span style="color: #ee3800; font-size: 12px; float: left;">(请输入0-1000的数字) 说明:功能模块有较大的变动，比如增加多个模块或者整体架构发生变化。此版本号由项目决定是否修改。</span>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label" style="width: 10%;">次版本号</div>
                <div class="col-sm-10" style="width: 90%;">
                    <input type="text" class="form-control" width="80%" v-model="appUpdate.minorno" placeholder="次版本号"/>
                    <span style="color: #ee3800; font-size: 12px; float: left; align-content: left">(请输入0-1000的数字)说明:功能有一定的增加或变化，比如增加了对权限控制、增加自定义视图等功能</span>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label" style="width: 10%;">修订版本号</div>
                <div class="col-sm-10" style="width: 90%;">
                    <input type="text" class="form-control" width="80%" v-model="appUpdate.reviseno" placeholder="修订版本号"/>
                    <span style="color: #ee3800; font-size: 12px; float: left; align-content: left">(请输入0-1000的数字)说明:一般是 Bug 修复或是一些小的变动，要经常发布修订版，时间间隔不限，修复一个严重的bug即可发布一个修订版</span>
                </div>
                <!--<div class="col-sm-2 control-label" style="width: 10%;"></div>-->
                <!--<div class="col-sm-10" style="width: 40%;">-->
                <!--<input type="text" class="form-control" width="80%" v-model="appUpdate.indexno" placeholder=""/>-->
                <!--</div>-->
            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label"></div>
                <input type="button" class="btn btn-primary" @click="saveOrUpdate" value="确定"/>
                &nbsp;&nbsp;<input type="button" class="btn btn-warning" @click="reload" value="返回"/>
            </div>
        </form>
    </div>


</div>

<script src="${request.contextPath}/statics/js/modules/appManagement/appupdate.js?_${.now?long}"></script>
</body>
</html>